package com.susallwave.srcb.response;

import lombok.Getter;

@Getter
public enum ResultEnum {
    SUCCESS(200, "操作成功"),
    ERROR(500, "系统错误"),
    UNAUTHORIZED(401, "未认证"),
    FORBIDDEN(403, "无权限"),
    NOT_FOUND(404, "资源不存在"),

    /**
     * 业务错误码 (按需扩展, 以10001,20001,30001分大类)
     * 系统管理以及通用的用10000 ,
     */
    NO_USER(10001,"用户不存在"),
    MORE_LOGIN_LOCK(10002,"密码输入次数过多,账户已锁定"),
    BANK_USER_INVALID(10003,"行内账户在绿金已锁定,请联系管理员处理"),
    PWD_ERROR(10004,"密码错误"),
    EXIST_USER(10005, "用户已存在"),
    FORBIDDEN_CHANGE_ACCT(10006, "禁止修改账号"),
    SIGN_NOT_MATCH(10007,"签名不匹配,登陆失败"),
    OVER_TIME(10008,"签名有效期10分钟,该链接签名无效"), PAGE_NOT_MATCH(10009,"pageCode不是预定值" ),
    REPEAT_CODE(10010,"重复编码" ),
    REPEAT_NAME(10011,"重复名称" ),
    ID_NULL(10012,"id不能为空"),;

    private final int code;
    private final String msg;

    ResultEnum(int code, String msg) {
        this.code = code;
        this.msg = msg;
    }
}
